<!DOCTYPE html>
{include file='head_hooks.html'}

<head>
  <title>{$project->name} settings | Protoweb</title>

  {include file='head_scripts.html'}
</head>

<body>
  {include file='body_hooks.html'}

  {include file='navbar.html'}

  <div class="container">

    {include file='messages.html'}
    
    <div class="row">

      <section class="span8">

        <form action="" method="post" enctype="multipart/form-data">
          <input name="id" type="hidden" value="{$project->id}" />

          <div class="control-group">
            <label for="name">Name *</label>
            <input class="input-xlarge" name="name" type="text" id="name" value="{$project->name}" required="required"/>
          </div>

          <div class="control-group">
            <label for="description">Description</label>
            <textarea  name="description" id="description" cols="45" rows="5" class="input-xlarge">{$project->description}</textarea>
          </div>

          <div class="control-group">
            <label for="default_entity">Default Entity</label>
            <select name="default_entity" class="input-xlarge">
            {foreach from=$project->entity item="ent"}
              <option value="{$ent->pural}">{$ent->singular}</option>
            {/foreach}
            </select>
          </div>

          <div class="control-group">
            <button type="submit" class="btn btn-primary">Save</button>
          </div>

        </form>
        
      </section>
      <!-- span8 -->

      <section class="span4">
        <h2>Project actions</h2>
        <p><a href='projects/dashboard/{$project->id}/'>Dashboard</a></p>
        <p><a href='projects/work/{$project->id}/'>Work!</a></p>
        <p><a href='entities/create/{$project->id}/'>Create entity</a></p>
        <hr />
        <p><a href='{$project->base_url()}' target="_BLANK">Go to project index</a></p>
        <hr />
        <p><a href='projects/edit/{$project->id}/'>Basic settings</a></p>
        <p><a href='projects/members/{$project->id}/'>Edit members</a></p>
      </section>
      <!-- span4 -->

    </div>
    <!-- row -->

    {include file='footer.html'}

  </div> <!-- /container -->

  {include file='footer_scripts.html'}

</body>

</html>
